The present invention relates to converting signals, and more particularly to conversion of bi-directional signals characterized in that the signal includes indicia corresponding to a distance, in time or position, and that a converted signal comprises further indicia corresponding to a non-integral multiple of the indicia.
By way of example, in machine tool and position indication applications, encoders (be they rotational, linear or the like) are used to indicate a position of a work piece or a machine part. It is often necessary, however, to convert the output of the encoders (or position indicators) from their fixed number of indicia per unit (e.g., fixed number of indicia per unit of rotation, fixed number of indicia per unit of length, or otherwise) to a number of indicia per unit that corresponds to some aspect of the work piece or machine tool position.
Industry standard rotary shaft encoders, for example, are manufactured with many different numbers of counts per revolution (in many different resolutions) in an attempt to cover the mechanical and precision needs of machine tool position indication applications. However, the resolutions are limited to integer values, i.e., whole numbers of counts per revolution, leaving one to select only a close match, rather than the precise number of counts per revolution desired, and then to use custom gear trains, or complex processor-based computational conversion systems, in order to obtain a desired number of counts per revolution.
For example, to generate a converted output comprising a count, i.e., a pulse, every 0.5000 inches on the perimeter of a 25.000 inch diameter drum, and whose shaft is mechanically coupled to a 1120 count per revolution, i.e., pulse per revolution, rotary shaft encoder, it is necessary to convert the pulse output of the rotary shaft encoder from a whole number of pulses per revolution to a non-integer number of pulses per revolution.
At the same time, however, for machine tool applications, the converted output must be accurate at various, and varying rotational speeds, as well as accommodate reversals in direction as, for example, the drum is rotated forward and backward at various and varying speeds.
The present invention addresses the needs above as well as others.
The present invention addresses the above and other needs by providing a converter for receiving an input signal that includes indicia corresponding to a distance, in time or position, and for generating a converted signal including further indicia corresponding to a non-integral multiple of the indicia.
The present invention can be characterized, in accordance with one embodiment, as a method having steps of providing a clock signal input and a direction signal input to a principal counter, and then incrementing a count value when a pulse is received by the clock signal input while the direction signal input is at a first value. The count value is decremented when a pulse is received by the clock signal input while the direction signal input is at a second value. A count pulse output is generated from the principal counter and the count value is set to a minimum coefficient when another pulse is received by the clock signal input after a maximum coefficient has been reached while the direction signal input is at the first value. A count pulse output is generated from the principal counter and the count value is set to the maximum coefficient when another pulse is received by the clock signal input after the minimum coefficient (which may be zero) has been reached while the direction signal input is at the second value. In this way, a converted signal is produced as the count pulse output of the principal counter.
In accordance with a further embodiment, the present invention may be characterized as a system. A plurality of cascaded counters may be chained together to reset the maximum coefficient of N1 to N1+1 and to reset the maximum coefficient to N1 again for the principal counter. An output count signal of each counter is coupled to the clock signal input of respective next counter in the plurality of cascaded counters, with the exception of an output count signal of a last counter in the plurality of cascaded counters. The output count signal of the principle counter is coupled to the clock input signal of a first counter in the plurality of cascaded counters. The direction input signal is a direction input signal for each respective counter in the plurality of cascaded counters. Separate output signals are also activated at each respective counter in the plurality of cascaded counters once a maximum or minimum count value (minimum or maximum coefficient) is reached, which in turn activates, respectively, a count control or reload signal input of a previous counter in the plurality of cascaded counters to select whether a maximum coefficient for each respective counter in the plurality of cascaded counters is reset to Nx or Nx+1.
In accordance with one variation, the minimum coefficient for each respective counter may be reset to Mx+1, and reset to Mx instead of or in addition to the resetting of the maximum coefficient for each respective counter.
In accordance with yet a further variation, a count range, i.e., a difference between a minimum coefficient (starting value) and a maximum coefficient (rollover or xe2x80x9cstoppingxe2x80x9d value) for each counter may be reset to xcex94x+1., and reset to xcex94x. The counters may count up or down as a function of the direction input signal.